RealtimeArray<TValue>
RealtimeArray<TValue>
RealtimeArray is a special model type that holds a sequential list of models that can be modified at runtime. Modifying the array sends the minimal amount of information necessary for other clients to replicate the change. The whole collection is not sent every time.
Events
modelAdded
event ModelAdded<TValue> modelAdded
An event that fires when a model is added locally or remotely.
Properties
Count
int Count { get; }
The number of models currently stored in the collection.
Item
TValue Item { get; }
Retrieve a model given a specific index.
Methods
Add
void Add(TValue value)
Appends a RealtimeModel to the end of the array.
Add operations take effect instantly. If the server rejects a change (due to ownership) the model will be removed.
GetEnumerator
IEnumerator<TValue> GetEnumerator()
_ReadArrayUpdate
void _ReadArrayUpdate(ReadStream stream, StreamContext context, uint propertyID)
Internal. Do not use.
This will be removed in the next major version.
GetCollectionTypeID
uint GetCollectionTypeID()